import Vue from 'vue'
import Router from 'vue-router'
import Main from '@/view/Main'
import Detail from '@/view/Detail'
import Back from '@/view/Back'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      name: 'main',
      component: Main
    },
    {
      path: '/detail',
      name: 'detail',
      component: Detail
    },
    {
      path: '/back',
      name: 'back',
      component: Back,
      children:[
        {path:'backHouse',name:'BackHouse',component:()=>import('@/view/BackHouse')},
        {path:'back1',name:'Back1',component:()=>import('@/view/Back1')},
        {path:'back2',name:'Back2',component:()=>import('@/view/Back2')},
        {path:'back3',name:'Back3',component:()=>import('@/view/Back3')},
        {path:'back4',name:'Back4',component:()=>import('@/view/Back4')},
        {path:'back5',name:'Back5',component:()=>import('@/view/Back5')}
      ]
    }
  ]
})
